#include <cv.h>
#include <highgui.h>
#include "abstractProbabilityTransformer.hpp"
#include "abstractFilter.hpp"
#include "resourceTracker.h"
#include "faceDetector.h"
#include "AbstractHandTracker.hpp"
#include "HIVideoCapture.hpp"
#include "handLocaliser.hpp"

#include "AbstractHandTrackerTest.hpp"
#include "HandTrackerLKHSVCx.hpp"

#include <iostream>
//TODO clean up includes

//this looks up the location of the gtest files in header hiDependenciesForTestFramework.h
//TODO : Design choice? currently I'll keep this dependency in a very specific header file
// as changing it should cause minimal recompilation.

#include "hiDependenciesForTestFramework.h"
#include "gtest.h"

//NOTE: hiDependenciesForTestFramework sets HI_TEST_VISUALISATION
//which if set will make tests compile to show images of the things they test.

//FIXNOW: normalise error according to tracking rect size? (include both normalised and raw error)

using namespace cv;

class HandTrackerLKHSVCxTest : public ::AbstractHandTrackerTest {
protected:
	void setHandTracker(int trackerCode);
};


// -- test case codes -- //
#define ONE_TYPE_ONLY 0


void HandTrackerLKHSVCxTest::setHandTracker(int trackerCode) {
	
	ht = HandTrackerLKHSVCx::init( trackingRect, frame, trackerCode ); //Tracker code determines max number of corners tracked
	
}

TEST_F(HandTrackerLKHSVCxTest, C1locVid1c ) {
	testTracker( 1, "locVid1c" );
}

TEST_F(HandTrackerLKHSVCxTest, C10locVid1c ) {
	testTracker( 10, "locVid1c" );
}

TEST_F(HandTrackerLKHSVCxTest, C50locVid1c ) {
	testTracker( 50, "locVid1c" );
}

TEST_F(HandTrackerLKHSVCxTest, C100locVid1c ) {
	testTracker( 100, "locVid1c" );
}


TEST_F(HandTrackerLKHSVCxTest, C1TrackerTest1 ) {
	testTracker( 1, "TrackerTest1" );
}

TEST_F(HandTrackerLKHSVCxTest, C10TrackerTest1 ) {
	testTracker( 10, "TrackerTest1" );
}

TEST_F(HandTrackerLKHSVCxTest, C50TrackerTest1 ) {
	testTracker( 50, "TrackerTest1" );
}

TEST_F(HandTrackerLKHSVCxTest, C100TrackerTest1 ) {
	testTracker( 160, "TrackerTest1" );
}





			
			
		
		
		
